package cn.lyjuan.payment.third.base.common.mapper;

import cn.lyjuan.payment.third.base.common.entity.pay.PayRefundEntity;
import org.apache.ibatis.annotations.Param;

public interface PayRefundMapper {


    Integer selectRefundTotalAmt(@Param("tranId") Integer wTranId);

    /**
     * 找到未退款成功 旧的 退款no
     *
     * @param tranId         交易id
     * @param appRefundNo    app退款号
     * @param amount         曾经的退款金额
     * @param selfPayOrderNo 本平台的支付订单号
     * @return String
     */
    PayRefundEntity selectNotRefundSuccessOrderNo(
            @Param("tranId") Integer tranId,
            @Param("appRefundNo") String appRefundNo,
            @Param("amount") Integer amount,
            @Param("selfPayOrderNo") String selfPayOrderNo
    );

}